<template>
  <h3>这是关于页</h3>
  <p>城市: {{ cityName }}</p>
  <p>oddArr: {{ oddArr }}</p>
  <button @click="changeCity">change city</button>
</template>

<script setup lang="ts">
import { computed } from "vue";
import { useCity } from "../stores/city";

const cityStore = useCity();

const cityName = computed(() => cityStore.cityName);
const oddArr = computed(() => cityStore.oddArr);

const changeCity = () => {
  // cityStore.cityName = "杭州";
  cityStore.push();
};
</script>
